const joi = require('@hapi/joi')

exports.addArticleRuler = {
    body: {
        title: joi.string().required(),
        cate_id: joi.number().min(1).required(),
        content: joi.string().allow('').required(),
        state: joi.string().valid('已发布', '草稿').required()
    }
}